package gao.xiaolei.copyEntity;

import gao.xiaolei.entity.TestBase;
import gao.xiaolei.entity.TestRun;
import lombok.Data;
import org.hibernate.annotations.ColumnDefault;

import javax.persistence.Column;
import javax.persistence.Entity;

@Entity
@Data
public class TestRunCopy extends TestBase {
    @Column(name = "describe_text", columnDefinition = "text")
    private String describe;//测试集描述或者测试执行描述

    @Column
    private Integer priority;// 测试执行的优先级

    @Column
    private String testDesign;//执行的测试计划

    @Column(columnDefinition = "INT default 0")
    private Integer grade;//分数

    @Column(columnDefinition = "char(32)")
    private String judge;//评分人

    public TestRunCopy(TestRun testRun) {
        super(testRun.getId(), testRun.getTitle(), testRun.getAuthor(), testRun.getProject(), testRun.getStatus(), testRun.getLeaf(), testRun.getParentId(), testRun.getCreateDate(),testRun.getUpdateDate());
        this.describe = testRun.getDescribe();
        this.priority = testRun.getPriority();
        this.testDesign=testRun.getTestDesign();
        this.grade=0;
    }

    public TestRunCopy() {
    }
}
